import { onMounted, ref } from "vue";

export function useSalary() {
  const name = ref<string>('lily')
  const salary = ref<number | null>(1000)
  const submitted = ref<boolean>(false)

  const handleSubmit = (): void => {
    console.log('handleSubmit ')
    console.log(salary)
    submitted.value = true
  }

  onMounted(() => {
    // do something
    //console.log('i want to do something!')
  });

  return {name, salary, submitted, handleSubmit}
}



